<template>
  <swiper :options="swiperOption" class="banner-slide">
    <!-- slides -->
    <swiper-slide v-for="(item, index) in slides" :key="index">
      <img :src="item.image" />
    </swiper-slide>
    <!-- Optional controls -->
    <div class="swiper-pagination"  slot="pagination"></div>
  </swiper>
</template>

<script>
export default {
  name: 'BannerSlide',
  props: {
    slides: {
      type: Array,
      default: () => []
    }
  },
  data () {
    return {
      swiperOption: {}
    }
  }
}
</script>

<style lang="scss" scoped>
.banner-slide {
  img {
    @include wh(100%, auto)
  }
}
</style>
